package com.niit.schoolhub.system.pojo;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import java.io.Serializable;
import java.time.LocalDateTime;

import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;

/**
 * <p>
 * 博客-第三方登录表
 * </p>
 *
 * @author kaguya
 * @since 2021-11-27
 */
@TableName("yesapi_bjy_oauth_user")
@ApiModel(value = "YesapiBjyOauthUser对象", description = "博客-第三方登录表")
public class YesapiBjyOauthUser implements Serializable {

    private static final long serialVersionUID = 1L;

    @TableId(value = "id", type = IdType.AUTO)
    private Long id;

    @ApiModelProperty("关联的本站用户id")
    private Integer uid;

    @ApiModelProperty("类型 1：QQ  2：新浪微博 3：豆瓣 4：人人 5：开心网")
    private Integer type;

    @ApiModelProperty("第三方昵称")
    private String nickname;

    @ApiModelProperty("头像")
    private String headImg;

    @ApiModelProperty("第三方用户id")
    private String openid;

    @ApiModelProperty("access_token token")
    private String accessToken;

    @ApiModelProperty("绑定时间")
    private LocalDateTime createTime;

    @ApiModelProperty("最后登录时间")
    private LocalDateTime lastLoginTime;

    @ApiModelProperty("最后登录ip")
    private String lastLoginIp;

    @ApiModelProperty("登录次数")
    private Integer loginTimes;

    @ApiModelProperty("状态")
    private Boolean status;

    @ApiModelProperty("邮箱")
    private String email;

    @ApiModelProperty("是否是admin")
    private Boolean isAdmin;


    public Long getId() {
        return id;
    }

    public void setId(Long id) {
        this.id = id;
    }

    public Integer getUid() {
        return uid;
    }

    public void setUid(Integer uid) {
        this.uid = uid;
    }

    public Integer getType() {
        return type;
    }

    public void setType(Integer type) {
        this.type = type;
    }

    public String getNickname() {
        return nickname;
    }

    public void setNickname(String nickname) {
        this.nickname = nickname;
    }

    public String getHeadImg() {
        return headImg;
    }

    public void setHeadImg(String headImg) {
        this.headImg = headImg;
    }

    public String getOpenid() {
        return openid;
    }

    public void setOpenid(String openid) {
        this.openid = openid;
    }

    public String getAccessToken() {
        return accessToken;
    }

    public void setAccessToken(String accessToken) {
        this.accessToken = accessToken;
    }

    public LocalDateTime getCreateTime() {
        return createTime;
    }

    public void setCreateTime(LocalDateTime createTime) {
        this.createTime = createTime;
    }

    public LocalDateTime getLastLoginTime() {
        return lastLoginTime;
    }

    public void setLastLoginTime(LocalDateTime lastLoginTime) {
        this.lastLoginTime = lastLoginTime;
    }

    public String getLastLoginIp() {
        return lastLoginIp;
    }

    public void setLastLoginIp(String lastLoginIp) {
        this.lastLoginIp = lastLoginIp;
    }

    public Integer getLoginTimes() {
        return loginTimes;
    }

    public void setLoginTimes(Integer loginTimes) {
        this.loginTimes = loginTimes;
    }

    public Boolean getStatus() {
        return status;
    }

    public void setStatus(Boolean status) {
        this.status = status;
    }

    public String getEmail() {
        return email;
    }

    public void setEmail(String email) {
        this.email = email;
    }

    public Boolean getIsAdmin() {
        return isAdmin;
    }

    public void setIsAdmin(Boolean isAdmin) {
        this.isAdmin = isAdmin;
    }

    @Override
    public String toString() {
        return "YesapiBjyOauthUser{" +
        "id=" + id +
        ", uid=" + uid +
        ", type=" + type +
        ", nickname=" + nickname +
        ", headImg=" + headImg +
        ", openid=" + openid +
        ", accessToken=" + accessToken +
        ", createTime=" + createTime +
        ", lastLoginTime=" + lastLoginTime +
        ", lastLoginIp=" + lastLoginIp +
        ", loginTimes=" + loginTimes +
        ", status=" + status +
        ", email=" + email +
        ", isAdmin=" + isAdmin +
        "}";
    }
}
